<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        // 编写一个函数，计算三个数字的大小，按从小到大的顺序输出.
        function num(a,b,c){
            if(a-b>0 &&  b-c>0){
                console.log(c,b,a);
            }
            else if(c-a>0 && a-b>0){
                console.log(b,a,c);
            }
            else if(b-a>0 && a-c>0){
                console.log(c,a,b);
            }
            else if(a-c>0 && c-b>0){
                console.log(b,c,a);
            }
            else if(b-c<0 && b-a>0){
                console.log(a,b,c);
            }
            else if(b-c>0 && c-a>0){
                console.log(a,c,b);
            }
            else{
                console.log("输入错误，请重新输入")
            }
        }
        num();

    </script>
</body>
</html>